#coding=utf-8

# pyecharts==0.1.9.4

from pyecharts import Map,Geo

data = [
("赣州", 25),("广州", 10),("西安", 22),("长沙", 20),("北京", 20)]
 

geo = Geo("全国主要城市空气质量热力图", "data from pm2.5", title_color="#fff", title_pos="center", width=1200, height=600, background_color='#404a59')
 
attr, value = geo.cast(data)
geo.add("空气质量热力图", attr, value, visual_range=[0, 25], type='heatmap',visual_text_color="#fff", symbol_size=15, is_visualmap=True, is_roam=False)
geo.show_config()
geo.render(path="./html/demo.html")
